import request from '/@/utils/request';

/**
 * 后端控制菜单模拟json

 */

/**
 * 获取后端动态路由菜单(admin)

 * @param params 要传的参数值，非必传
 * @returns 返回接口数据
 */
export function getRolePageList(params?: object) {
    return request({
        url: '/api/system/role/query/page',
        method: 'get',
        params,
    });
}


export function saveRole(params: object) {
    return request({
        url: '/api/system/role/save',
        method: 'post',
        params,
    });
}


export function getRoleEntity(roleId?: String) {
    return request({
        url: '/api/system/role/query/' + roleId,
        method: 'get',
    });
}


export function deleteRoles(roleId: String) {
    return request({
        url: '/api/system/role/remove/' + roleId,
        method: 'delete',
    });
}
